<?php
/**
 * TestGuest Version1.0
 * ================================================
 * Copy 2017-2018 zxj
 * Web: http://www.zhaoxiaojie.club
 * ================================================
 * Author: Zxj
 * Date: 17/8/15
 * Time: 下午2:35
 *
 * 前台退出页面,接收ajax请求
 *
 */
session_start();

if(isset($_GET['act'])&&($_GET['act']=='logout')){

   $name = $_SESSION['pro_username'];
    if(session_destroy()){

        $data['status'] = 1;
        $data['msg'] = $name.',退出成功!';
        echo json_encode($data);
        exit();

    }else{

        $data['status'] = 0;
        $data['msg'] = $name.',退出失败!';
        echo json_encode($data);
        exit();

    }


}else{

    $data['status'] = 0;
    $data['msg'] ='数据异常!';
    echo json_encode($data);
    exit();

}


?>